POV-Ray : Newsgroups : povray.general : Auto focus.. : Re: Auto focus.. Server Time
31 Jul 2024 12:19:56 EDT (-0400)
  Re: Auto focus..  
From: Alain
Date: 8 Mar 2007 19:25:30
Message: <45f0a97a$1@news.povray.org>
Raf256 nous apporta ses lumieres en ce 08-03-2007 12:10:
> Can someone refresh my memory,

> we have an object OBJ which is in front of the camera, how to auto focus on
> it?

> camera {
>   #local POS = <1,2,3>; // camera position
>   location <POS>

>   #local FOC = .... ; // get the focal point

>   blure_samples ...
>   focal_point FOC

>   rotate ...   translate.. // <-- some easy way to have this working too?
>   // lets assume I grouped thoes into a #define TRANS = transform { .... }
> }

Set focal_point to the location of that object. Easy if the object is created 
around the origin then translated, set the translation vector in a #declare and 
use that same value for the focal_point.
Something like:
#declare ObjLoc = <X,Y,Z>;
object{YourObject translate ObjLoc}
camera{... focal_point ObjLoc...}

-- 
Alain
-------------------------------------------------
A Bill of Rights is what the people are entitled to against every
government, and what no just government should refuse, or rest on inference.
Thomas Jefferson


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.